using UnityEngine;

namespace DG.Tweening
{
    // [Assembly-CSharp-firstpass.dll].DG.Tweening.DOTweenModuleSprite
    public static class DOTweenModuleSprite
    {
        
        #region DG.Tweening.DOTweenModuleSprite.<>c__DisplayClass0_0
        // [Assembly-CSharp-firstpass.dll].DG.Tweening.DOTweenModuleSprite.<>c__DisplayClass0_0
        private sealed class __c__DisplayClass0_0
        {
            // Fields
            public UnityEngine.SpriteRenderer target;
            
            // Methods
            public __c__DisplayClass0_0()
            {
            
            }
            internal UnityEngine.Color <DOColor>b__0()
            {
                return this.target.color;
            }
            internal void <DOColor>b__1(UnityEngine.Color x)
            {
                this.target.color = new UnityEngine.Color() {r = x.r, g = x.g, b = x.b, a = x.a};
            }
        
        }
        
        #endregion
        
        
        #region DG.Tweening.DOTweenModuleSprite.<>c__DisplayClass1_0
        // [Assembly-CSharp-firstpass.dll].DG.Tweening.DOTweenModuleSprite.<>c__DisplayClass1_0
        private sealed class __c__DisplayClass1_0
        {
            // Fields
            public UnityEngine.SpriteRenderer target;
            
            // Methods
            public __c__DisplayClass1_0()
            {
            
            }
            internal UnityEngine.Color <DOFade>b__0()
            {
                return this.target.color;
            }
            internal void <DOFade>b__1(UnityEngine.Color x)
            {
                this.target.color = new UnityEngine.Color() {r = x.r, g = x.g, b = x.b, a = x.a};
            }
        
        }
        
        #endregion
        
        
        #region DG.Tweening.DOTweenModuleSprite.<>c__DisplayClass3_0
        // [Assembly-CSharp-firstpass.dll].DG.Tweening.DOTweenModuleSprite.<>c__DisplayClass3_0
        private sealed class __c__DisplayClass3_0
        {
            // Fields
            public UnityEngine.Color to;
            public UnityEngine.SpriteRenderer target;
            
            // Methods
            public __c__DisplayClass3_0()
            {
            
            }
            internal UnityEngine.Color <DOBlendableColor>b__0()
            {
                return new UnityEngine.Color() {r = this.to};
            }
            internal void <DOBlendableColor>b__1(UnityEngine.Color x)
            {
                this.to = x;
                mem[1152921504930430420] = x.g;
                mem[1152921504930430424] = x.b;
                mem[1152921504930430428] = x.a;
                UnityEngine.Color val_5 = this.target.color;
                val_5.r = (x.r - this.to) + val_5.r;
                val_5.g = (x.g - S5) + val_5.g;
                val_5.b = (x.b - S6) + val_5.b;
                val_5.a = (x.a - S7) + val_5.a;
                this.target.color = new UnityEngine.Color() {r = val_5.r, g = val_5.g, b = val_5.b, a = val_5.a};
            }
        
        }
        
        #endregion
        
        // Methods
        public static DG.Tweening.Core.TweenerCore<UnityEngine.Color, UnityEngine.Color, DG.Tweening.Plugins.Options.ColorOptions> DOColor(UnityEngine.SpriteRenderer target, UnityEngine.Color endValue, float duration)
        {
            object val_1 = 536898061;
            val_1 = new System.Object();
            mem[536898077] = target;
            DG.Tweening.Core.DOGetter<UnityEngine.Color> val_2 = 536873937;
            val_2 = new DG.Tweening.Core.DOGetter<UnityEngine.Color>(object:  val_1, method:  1610682009);
            DG.Tweening.Core.DOSetter<UnityEngine.Color> val_3 = 536873979;
            val_3 = new DG.Tweening.Core.DOSetter<UnityEngine.Color>(object:  val_1, method:  1610682011);
            DG.Tweening.Core.TweenerCore<UnityEngine.Color, UnityEngine.Color, DG.Tweening.Plugins.Options.ColorOptions> val_4 = DG.Tweening.DOTween.To(getter:  val_2, setter:  val_3, endValue:  new UnityEngine.Color() {r = endValue.r, g = endValue.g, b = endValue.b, a = endValue.a}, duration:  duration);
            Unknown val_5 = DG.Tweening.TweenSettingsExtensions.SetTarget<System.Object>(t:  val_4, target:  mem[536898077]);
            return val_4;
        }
        public static DG.Tweening.Core.TweenerCore<UnityEngine.Color, UnityEngine.Color, DG.Tweening.Plugins.Options.ColorOptions> DOFade(UnityEngine.SpriteRenderer target, float endValue, float duration)
        {
            object val_1 = 536898063;
            val_1 = new System.Object();
            mem[536898079] = target;
            DG.Tweening.Core.DOGetter<UnityEngine.Color> val_2 = 536873937;
            val_2 = new DG.Tweening.Core.DOGetter<UnityEngine.Color>(object:  val_1, method:  1610682015);
            DG.Tweening.Core.DOSetter<UnityEngine.Color> val_3 = 536873979;
            val_3 = new DG.Tweening.Core.DOSetter<UnityEngine.Color>(object:  val_1, method:  1610682017);
            DG.Tweening.Core.TweenerCore<UnityEngine.Color, UnityEngine.Color, DG.Tweening.Plugins.Options.ColorOptions> val_4 = DG.Tweening.DOTween.ToAlpha(getter:  val_2, setter:  val_3, endValue:  endValue, duration:  duration);
            Unknown val_5 = DG.Tweening.TweenSettingsExtensions.SetTarget<System.Object>(t:  val_4, target:  mem[536898079]);
            return val_4;
        }
        public static DG.Tweening.Sequence DOGradientColor(UnityEngine.SpriteRenderer target, UnityEngine.Gradient gradient, float duration)
        {
            var val_14 = 27344528;
            DG.Tweening.Sequence val_1 = DG.Tweening.DOTween.Sequence();
            if(val_2.Length < 1)
            {
                goto label_14;
            }
            
            if(val_2.Length == 1)
            {
                goto label_13;
            }
            
            val_14 = 0;
            label_15:
            if((val_14 == 0) && (null <= 0f))
            {
                    target.color = new UnityEngine.Color() {r = 5.580343E-26f, g = 5.580343E-26f, b = 5.580343E-26f, a = 5.580343E-26f};
            }
            else
            {
                    if((val_2.Length - 1) == val_14)
            {
                    float val_7 = duration - (DG.Tweening.TweenExtensions.Duration(t:  val_1, includeLoops:  false));
            }
            else
            {
                    if(val_14 != 0)
            {
                    if((val_14 - 1) >= val_2.Length)
            {
                goto label_13;
            }
            
            }
            
            }
            
                DG.Tweening.Sequence val_13 = DG.Tweening.TweenSettingsExtensions.Append(s:  val_1, t:  DG.Tweening.TweenSettingsExtensions.SetEase<System.Object>(t:  DG.Tweening.DOTweenModuleSprite.DOColor(target:  target, endValue:  new UnityEngine.Color() {r = 5.580343E-26f, g = 5.580343E-26f, b = 5.580343E-26f, a = 5.580343E-26f}, duration:  (null - null) * duration), ease:  1));
            }
            
            if(((val_2.Length & 4294967295) - 1) == val_14)
            {
                goto label_14;
            }
            
            val_14 = val_14 + 1;
            if(val_14 < val_2.Length)
            {
                goto label_15;
            }
            
            label_13:
            label_14:
            Unknown val_14 = DG.Tweening.TweenSettingsExtensions.SetTarget<System.Object>(t:  val_1, target:  target);
            return val_1;
        }
        public static DG.Tweening.Tweener DOBlendableColor(UnityEngine.SpriteRenderer target, UnityEngine.Color endValue, float duration)
        {
            float val_9 = endValue.b;
            float val_8 = endValue.g;
            float val_7 = endValue.r;
            object val_1 = 536898065;
            val_1 = new System.Object();
            mem[536898097] = target;
            UnityEngine.Color val_2 = mem[536898097].color;
            mem[536898081] = 0;
            mem[536898089] = 0;
            DG.Tweening.Core.DOGetter<UnityEngine.Color> val_3 = 536873937;
            float val_10 = val_2.a;
            val_3 = new DG.Tweening.Core.DOGetter<UnityEngine.Color>(object:  val_1, method:  1610682021);
            DG.Tweening.Core.DOSetter<UnityEngine.Color> val_4 = 536873979;
            val_7 = val_7 - val_2.r;
            val_8 = val_8 - val_2.g;
            val_9 = val_9 - val_2.b;
            val_10 = endValue.a - val_10;
            val_4 = new DG.Tweening.Core.DOSetter<UnityEngine.Color>(object:  val_1, method:  1610682023);
            return DG.Tweening.TweenSettingsExtensions.SetTarget<System.Object>(t:  DG.Tweening.Core.Extensions.Blendable<UnityEngine.Color, UnityEngine.Color, DG.Tweening.Plugins.Options.ColorOptions>(t:  DG.Tweening.DOTween.To(getter:  val_3, setter:  val_4, endValue:  new UnityEngine.Color() {r = val_7, g = val_8, b = val_9, a = val_10}, duration:  duration)), target:  mem[536898097]);
        }
    
    }

}
